﻿
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Data.Entity;

namespace ORMEntityFrameworkXJ
{
    public class DbInit : DropCreateDatabaseAlways<Admin1314DbContex>
    {

        protected override void Seed(Admin1314DbContex context)
        {
           

            var user = new Users
            {
                UserName = "admin",
                Password = "123",
                IsActived = true,
                IsDeleted = false,
                CreatedTime = DateTime.Now,
                UpdatedTime = DateTime.Now,
                Remarks = "小俊有点忧伤"
            };

            context.Users.Add(user);

            base.Seed(context);
        }
    }
}
